package com.zheng.redpacket.api;

/**
 * 常见http状态码
 * @author zheng
 */
public enum ResultCode implements RequestErrorCode {
    SUCCESS(200, "操作成功"),
    FAILED(500, "操作失败"),
    VALIDATE_FAILED(402, "参数检验失败"),
    FORBIDDEN(403, "非法授权类型");

    private Integer code;
    private String message;

    private ResultCode(Integer code, String message){
        this.code = code;
        this.message = message;
    }


    @Override
    public Integer getCode() {
        return code;
    }

    @Override
    public String getMessage() {
        return message;
    }
}
